/**
 * http://usejsdoc.org/
 */
var Person = require("./person"),
	Student = require("./student"),
	Teacher = require("./teacher"),
	Coder = require("./coder");

/**实例化对象*/
var personObj = new Person(),
	studentObj = new Student(),
	teacherObj = new Teacher(),
	coderObj = new Coder();

/**执行personObj对象的所有方法 sleep和eat*/
console.log("for base class of person");
personObj.sleep();
personObj.eat();
console.log("---------------------");

/**执行studentObj对象的所有方法 sleep、eat和study*/
console.log("for class of student");
studentObj.sleep();
studentObj.eat();
studentObj.study();
console.log("---------------------");


/**执行teacherObj对象的所有方法 sleep、eat和teach*/
console.log("for class of teacher");
teacherObj.sleep();
teacherObj.eat();
teacherObj.teach();
console.log("---------------------");


/**执行coderObj对象的所有方法 sleep、eat和code*/
console.log("for class of coder");
coderObj.sleep();
coderObj.eat();
coderObj.code();
console.log("---------------------");